<div class="main-content">
    <div class="breadcrumbs" id="breadcrumbs">
        <script type="text/javascript">
            try{ace.settings.check('breadcrumbs' , 'fixed')}catch(e){}
        </script>

        <ul class="breadcrumb">
            <li>
                <i class="icon-home home-icon"></i>
                <a href="#">Home</a>
            </li>

            <li>
                <a href="#">Forms</a>
            </li>
            <li class="active">Form Elements</li>
        </ul><!-- .breadcrumb -->

        <div class="nav-search" id="nav-search">
            <form class="form-search">
								<span class="input-icon">
									<input type="text" placeholder="Search ..." class="nav-search-input" id="nav-search-input" autocomplete="off" />
									<i class="icon-search nav-search-icon"></i>
								</span>
            </form>
        </div><!-- #nav-search -->
    </div>

    <div class="page-content">
        <div class="page-header">
            <h1>
                活动管理
                <small>
                    <i class="icon-double-angle-right"></i>
                    活动修改
                </small>
            </h1>
        </div><!-- /.page-header -->

        <div class="row">
            <div class="col-xs-12">
                <!-- PAGE CONTENT BEGINS -->

                <form class="form-horizontal" role="form" method="post" enctype="multipart/form-data" action="{:url('active/update',['id'=>$list['id']])}">
                    <div class="form-group">
                        <label class="col-sm-3 control-label no-padding-right" for="form-field-1"> wifi名称 </label>

                        <div class="col-sm-9">
                            <input type="text" name="name" id="form-field-1" placeholder="wifi名称" value="{$list.name}"
                                   class="col-xs-10 col-sm-5" />
                        </div>
                    </div>

                    <div class="space-4"></div>

                    <div class="form-group">
                        <label class="col-sm-3 control-label no-padding-right" for="form-field-2">wifi地点</label>

                        <div class="col-sm-9">
                            <input type="text" name="address" value="{$list.address}" id="form-field-2" placeholder="wifi地点"
                                   class="col-xs-10 col-sm-5" />
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-3 control-label no-padding-right" > 搜索地点 </label>

                        <div class="col-sm-9">
                            <iframe id="mapPage" width="400px" height="800px" frameborder=0
                                    src="https://apis.map.qq.com/tools/locpicker?search=1&type=1&key=363BZ-XLIKS-EIZOP-6PQGH-5W3YQ-X3B2J&referer=myapp">
                            </iframe>

                            <script>
                                window.addEventListener('message', function(event) {
                                    // 接收位置信息，用户选择确认位置点后选点组件会触发该事件，回传用户的位置信息
                                    var loc = event.data;
                                    if (loc && loc.module == 'locationPicker') {
                                        //防止其他应用也会向该页面post信息，需判断module是否为'locationPicker'
                                        $("#address").val(loc.poiaddress);
                                        $("#lat").val(loc.latlng.lat);
                                        $("#lng").val(loc.latlng.lng);
                                        //console.log(loc);
                                        //console.log('location', loc);
                                    }
                                }, false);
                            </script>
                        </div>
                    </div>
                    <div class="space-4"></div>
                    <div class="form-group">
                        <label class="col-sm-3 control-label no-padding-right" for="form-field-2">wifi经度</label>

                        <div class="col-sm-9">
                            <input type="text" name="lat" value="{$list.lat}" readonly placeholder="wifi经度" lat="lat"
                                   class="col-xs-10 col-sm-5" />
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-3 control-label no-padding-right"  >wifi纬度</label>

                        <div class="col-sm-9">
                            <input type="text" name="lng" value="{$list.lng}" readonly placeholder="wifi纬度" id="lng"
                                   class="col-xs-10 col-sm-5" />
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-3 control-label no-padding-right" for="form-field-2">腾讯地点</label>

                        <div class="col-sm-9">
                            <input type="text" name="address" value="{$list.address}"  placeholder="wifi地点" id="address"
                                   class="col-xs-10 col-sm-5" />
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-3 control-label no-padding-right" > 运行起始日期 </label>

                        <div class="col-sm-9">
                            <input type="text" name="start_time" placeholder="运行起始日期 " value="{:date('Y-m-d H:i:s',$list['addtime'])}"
                                   class="laydate-icon col-xs-10 col-sm-5" onclick="laydate({istime:true,format: 'YYYY-MM-DD hh:mm:ss'})"/>
                        </div>
                    </div>
                    <div class="clearfix form-actions">
                        <div class="col-md-offset-3 col-md-9">
                            <button class="btn btn-info" type="submit">
                                <i class="icon-ok bigger-110"></i>
                                修改
                            </button>
                            &nbsp; &nbsp; &nbsp;
                            <button class="btn" type="reset">
                                <i class="icon-undo bigger-110"></i>
                                重置
                            </button>
                        </div>
                    </div>
                </form>
                
            </div><!-- /.col -->
        </div><!-- /.row -->
    </div><!-- /.page-content -->
</div><!-- /.main-content -->